package com.zengyan.gd.model;


import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

import lombok.Data;

////@Table（name = "relationship"）
//CREATE TABLE `relationship` (
//        `relationship_id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '关系id',
//        `student_num` varchar(64) NOT NULL COMMENT '学号',
//        `organization_id` int(11) NOT NULL COMMENT '组织id',
//        `level` tinyint(3) NOT NULL DEFAULT '1' COMMENT '职称等级',
//        `create_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
//        `update_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '创建时间',
//        `department` int(3) unsigned DEFAULT '0',
//        PRIMARY KEY (`relationship_id`),
//        KEY `uqe_organizaton_id` (`organization_id`),
//        KEY `uqe_student_num` (`student_num`)
//        ) ENGINE=InnoDB DEFAULT CHARSET=utf8;

@Data
@Entity
@Table(name = "relationship")
public class Relationship {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "relationship_id")
    private int id;

    @Column(name = "student_num")
    private String studentNum;

    @Column(name = "organization_id")
    private int orgId;

    private int level;

    private int department;


}

